package com.epoint.mobileoa.bizlogic.mobileoa;

import java.util.HashMap;

import android.os.Message;

import com.epoint.mobileoa.bizlogic.SuperView;
import com.epoint.mobileoa.bizlogic.Task;
import com.epoint.mobileoa.http.HttpHelp;
import com.epoint.mobileoa.tools.PhoneHelp;
import com.epoint.mobileoa.tools.PropertiesHelp;

/**
 * @author liyc
 * @time 2012-2-21 下午11:05:08
 * @annotation 
 */
public class CheckLoginTask extends Task {

	public CheckLoginTask(SuperView con, HashMap<String, Object> param) {
		super(con, param);
	}

	@Override
	public void exectue(Message mess) throws Exception{
		String loginid = (String) getParam().get("loginid");
		String password = (String) getParam().get("password");
		String statisticsMobileOAStatus = PropertiesHelp.getProperty(getCon(), "statisticsMobileOAStatus");
		String checkRegisterInfo = PropertiesHelp.getProperty(getCon(), "checkRegisterInfo");
		String deviceid = PhoneHelp.getDeviceId(getCon());
		String seamurl = generateURL("loginCheck",loginid,password,statisticsMobileOAStatus,deviceid,checkRegisterInfo);
		String bs = HttpHelp.getHttpBack(seamurl);
		setMessageToRefreshUI(mess, getCon(), bs);
	}

}
